<?php

/**
 * 文件信息操作接口
 * Class SplFileInfo
 */

class SplFileInfo  {

	/**
	 * 初始化一个新的SplFileInfo对象
	 * @param string $file_name
	 */
	public function __construct ($file_name) {}

	/**
	 * 获取文件路径
	 * @return string the path to the file.
	 */
	public function getPath () {}

	/**
	 * 获取文件名
	 * @return string The filename.
	 */
	public function getFilename () {}

	/**
	 * 获取文件扩展名
	 * @return string 如果文件没有扩展名，就返回空字符串
	 */
	public function getExtension () {}

	/**
	 * 获取文件基本名称
	 * @param string $suffix [optional]
	 * Optional suffix to omit from the base name returned.
	 *@return string the base name without path information.
	 */
	public function getBasename ($suffix = null) {}

	/**
	 * Gets the path to the file
	 * @return string The path to the file.
	 */
	public function getPathname () {}

	/**
	 * 获取文件/文件夹权限
	 * @return int the file permissions.
	 */
	public function getPerms () {}

	/**
	 * 取得文件的 inode
	 * @return int the inode number for the filesystem object.
	 */
	public function getInode () {}

	/**
	 * 获取文件大小（单位:bytes）
	 * @return int The filesize in bytes.
	 */
	public function getSize () {}

	/**
	 * 获取文件所属者
	 * @return int The owner id in numerical format.
	 */
	public function getOwner () {}

	/**
	 * 获取文件所属组
	 * @return int The group id in numerical format.
	 */
	public function getGroup () {}

	/**
	 * 获取文件的最后访问时间
	 * @return int the time the file was last accessed.
	 */
	public function getATime () {}

	/**
	 * 获取文件的最后修改时间
	 * @return int the last modified time for the file, in a Unix timestamp.
	 */
	public function getMTime () {}

	/**
	 * 获取inode的变更时间
	 * @return int The last change time, in a Unix timestamp.
	 */
	public function getCTime () {}

	/**
	 * 获取文件类型
	 * @return string A string representing the type of the entry.
	 * 可能是: 文件/软连接/目录
	 */
	public function getType () {}

	/**
	 * 是否可写
	 * @return bool true if writable, false otherwise;
	 */
	public function isWritable () {}

	/**
	 * 是否可读
	 * @return bool true if readable, false otherwise.
	 */
	public function isReadable () {}

	/**
	 * 是否可执行
	 * @return bool true if executable, false otherwise.
	 */
	public function isExecutable () {}

	/**
	 * 是否是常规文件(软连接不算)
	 * @return bool true if the file exists and is a regular file (not a link), false otherwise.
	 */
	public function isFile () {}

	/**
	 * 是否是目录
	 * @return bool true if a directory, false otherwise.
	 */
	public function isDir () {}

	/**
	 * 是否是软连接
	 * @return bool true if the file is a link, false otherwise.
	 */
	public function isLink () {}

	/**
	 * 获取软连接真实目标
	 * @return string the target of the filesystem link.
	 */
	public function getLinkTarget () {}

	/**
	 * 获取文件的绝对路径
	 * @return string the path to the file.
	 */
	public function getRealPath () {}

	/**
	 * Gets an SplFileInfo object for the file
	 * @param string $class_name [optional]
	 * Name of an <b>SplFileInfo</b> derived class to use.
	 * @return SplFileInfo An <b>SplFileInfo</b> object created for the file.
	 */
	public function getFileInfo ($class_name = null) {}

	/**
	 * Gets an SplFileInfo object for the path
	 * @param string $class_name [optional]
	 * Name of an <b>SplFileInfo</b> derived class to use.
	 * @return SplFileInfo an <b>SplFileInfo</b> object for the parent path of the file.
	 */
	public function getPathInfo ($class_name = null) {}

	/**
	 * Gets an SplFileObject object for the file
	 * @param string $open_mode [optional] <p>
	 * The mode for opening the file. See the <b>fopen</b>
	 * documentation for descriptions of possible modes. The default
	 * is read only.
	 * </p>
	 * @param bool $use_include_path [optional] <p>
	 * &parameter.use_include_path;
	 * </p>
	 * @param resource $context [optional] <p>
	 * &parameter.context;
	 * </p>
	 * @return SplFileObject The opened file as an <b>SplFileObject</b> object.
	 * @since 5.1.2
	 */
	public function openFile ($open_mode = 'r', $use_include_path = false, $context = null) {}

	/**
	 * Sets the class name used with <b>SplFileInfo::openFile</b>
	 * @param string $class_name [optional] <p>
	 * The class name to use when openFile() is called.
	 * </p>
	 * @return void
	 * @since 5.1.2
	 */
	public function setFileClass ($class_name = null) {}

	/**
	 * Sets the class used with getFileInfo and getPathInfo
	 * @link http://php.net/manual/en/splfileinfo.setinfoclass.php
	 * @param string $class_name [optional] <p>
	 * The class name to use.
	 * </p>
	 * @return void
	 * @since 5.1.2
	 */
	public function setInfoClass ($class_name = null) {}

	/**
	 * Returns the path to the file as a string
	 * @return string the path to the file.
	 * @since 5.1.2
	 */
	public function __toString () {}
}